//
//  MineBuyYBViewController.m
//  TEst
//
//  Created by   丛熠超 on 2017/4/9.
//  Copyright © 2017年 Tongcheng. All rights reserved.
//

#import "MineBuyYBViewController.h"
#import "MIneYBbuyViewController.h"
#import "MIneChongzhiViewController.h"

@interface MineBuyYBViewController ()<DLTabedSlideViewDelegate>

@end

@implementation MineBuyYBViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.navigationItem.title = @"充值";
    self.TabedSlideView.baseViewController = self;
    self.TabedSlideView.flag = @"1";
    self.TabedSlideView.tabItemNormalColor = [UIColor blackColor];
    self.TabedSlideView.tabItemSelectedColor = RGB(0xF95880);
    self.TabedSlideView.delegate = self;
    
    self.TabedSlideView.tabNormalBackcolor = [UIColor whiteColor];
    self.TabedSlideView.tabSelectBackcolor = [UIColor whiteColor];
    
    self.TabedSlideView.tabbarTrackColor = RGB(0xF95880);
    self.TabedSlideView.tabbarBackgroundImage = [UIImage imageNamed:@"tabbarBk"];
    self.TabedSlideView.tabbarBottomSpacing = 3.0;
    
    DLTabedbarItem *item1 = [DLTabedbarItem itemWithTitle:@"购买Y币" image:[UIImage imageNamed:@""] selectedImage:[UIImage imageNamed:@""] normalColor:[UIColor blackColor] selectColor:[UIColor whiteColor]];
    DLTabedbarItem *item2 = [DLTabedbarItem itemWithTitle:@"开通VIP" image:[UIImage imageNamed:@""] selectedImage:[UIImage imageNamed:@""] normalColor:[UIColor blackColor] selectColor:[UIColor whiteColor]];
   
    
    self.TabedSlideView.tabbarItems = @[item1, item2];
    [self.TabedSlideView buildTabbar];
    //    self.tabedSlideView.barView.frame = CGRectMake(50, 0, 200, 50);
       self.TabedSlideView.selectedIndex = self.index;
    // Do any additional setup after loading the view from its nib.
}

- (NSInteger)numberOfTabsInDLTabedSlideView:(DLTabedSlideView *)sender{
    return 2;
}
- (UIViewController *)DLTabedSlideView:(DLTabedSlideView *)sender controllerAt:(NSInteger)index{
    switch (index) {
        case 0:
        {
            MIneYBbuyViewController *ctrl = [[MIneYBbuyViewController alloc] init];
            return ctrl;
        }
        case 1:
        {
            MIneChongzhiViewController *two = [[MIneChongzhiViewController alloc] init];
            return two;
        }
       
            
        default:
            return nil;
    }
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
